Secure recovery apparatus and method

ABSTRACT

A system and method is disclosed for recovering a boot image from a secure location. Hardware instructions initiate a sequence of boot cycles to launch a computer operating system on a computer-enabled device. During the boot cycles, multiple levels of boot code are verified and a determination is made whether each level is usable by the device. If a level of boot code is determined to be unusable, a secure copy of the boot code is loaded from a secure read-only location to repair the unusable code to launch the computer operating system.

TECHNICAL FIELD

The subject technology relates generally to computer recovery systems and methods, namely recovering an operating system or firmware.

BACKGROUND

Some computers (for example, notebooks) support a recovery mode, which is capable of restoring a computer back to a good state when its rewritable operating system and/or firmware becomes corrupted or compromised. Generally, a user initiates a recovery mode via a keystroke on boot-up of the computer. In some cases, the notebook can initiate the recovery mode on its own, if it determines there is a problem with the firmware and/or operating system. While the foregoing solution has been the mainstream approach, the user nevertheless needs a separate recovery device. If the user doesn't have a recovery device (SD card or USB stick), the user must create one by downloading and running an installer on a second computer. After the recovery device is inserted, the system will boot from recovery device and attempt to repair itself. If the user has an old recovery device, the user must first manually update it.

SUMMARY

The subject technology provides a system and method for loading a boot image from a secure location. The system includes a machine-readable medium having machine-executable instructions stored thereon, which when executed by a machine or computer cause the machine or computer to perform a method of loading a boot image. According to one aspect, the method includes initiating a sequence of boot cycles, each cycle loading a level of boot code from a memory medium, determining a level of boot code is unusable, and loading a secure copy of the level of boot code from a secure read-only location, wherein the secure read-only location is not associated with the memory medium. The secure read-only location may include an integrated circuit chip located on a system control board of a computer. In another aspect, the method may include verifying a last known verifiable level of code before determining the level of boot code is unusable, stopping the sequence of boot cycles on determining the level of boot code is unusable, repairing the unusable level of boot code using the secure copy, and resuming the boot cycle at the last known verifiable level. The method may be initiated automatically on the detection of a boot failure, or on indication by a user (for example, via, a dedicated button or keystroke during boot-up of the machine or computer).

It is understood that other configurations of the subject technology will become readily apparent to those skilled in the art from the following detailed description, wherein various configurations of the subject technology are shown and described by way of illustration. As will be realized, the subject technology is capable of other and different configurations and its several details are capable of modification in various other respects, all without departing from the scope of the subject technology. Accordingly, the drawings and detailed description are to be regarded as illustrative in nature and not as restrictive.

BRIEF DESCRIPTION OF THE DRAWINGS

A detailed description will be made with reference to the accompanying drawings:

FIG. 1 is an exemplary diagram of an apparatus and system for loading a boot image, including a firmware and secure memory location, according to one aspect of the subject technology.

FIG. 2 is an exemplary diagram of an apparatus and system for restoring an operating system over a network according to one aspect of the subject technology.

FIG. 3 is a flowchart illustrating an exemplary process for loading a boot image from a secure location according to one aspect of the subject technology.

FIG. 4 is a diagram illustrating an exemplary server system for loading a boot image from a secure location, including a processor and other internal components, according to one aspect of the subject technology.

DETAILED DESCRIPTION

Modern computers may include various backup and recovery mechanisms. Due to data corruption (for example, resulting from malicious software or hardware failures), it may be desirable to replace or repair an image of firmware or an operating system on a bootable hard drive or other storage mechanism. However, restoring the image using a recovery image may be a complex, if not a difficult process, and the recovery image itself may also be susceptible to data corruption. Thus, recovering a corrupted image may inevitably require intervention by a computer technician at substantial cost. The subject technology provides a secure bank of data that a user can turn to when everything else fails, alleviating the need for intervention by the user or computer technician.

FIG. 1 is an exemplary diagram of an apparatus and system for loading a boot image, including a firmware and secure memory location, according to one aspect of the subject technology. According to one aspect, a computer system 100 may include a system board 101 (for example, a motherboard), including a processor 102 and one or more firmware 103, and a hard drive 104. System 100 may be configured to startup operations using one or more boot images 105 spanning both firmware, kernel partitions, and/or a root file system of an operating system, with each boot image including multiple levels of boot code. For example, a boot image 105 may be stored on hard drive 104. In other aspects, one or more redundant boot images 106 may be included (for example, on a hidden partition of hard drive 104 or other rewritable memory) which correspond to and are redundant to boot image 105, providing a copy of boot image 105 should it fail.

System 100 may also include a secure memory location 107 associated with, or located on, system board 101. For example, secure memory location 107 may be implemented as an integrated circuit chip located on, or integrated with, system control board 101. This secure bank of data may be implemented as a secure read-only memory hardware that stores one or more secure images 108, including a trusted boot code for restoring all or a portion of a boot path of a computer-enabled device. In one aspect, secure image 108 may provide a copy of boot image 105. Because it is a read-only copy of a known good image, and separated from the kernel and/or hard disk, the boot code therein may be considered trusted. In some aspects, on a boot failure, a recovery using secure image 108 may be triggered by a hardware switch or by a series of keystrokes during the boot cycle. In other aspects, as described below, secure memory location 107 may be automatically accessed by system 100 on the boot failure.

Firmware 103 may include initiation and recovery instructions 109, that, when executed by the processor, may be operable to cause the processor to load and perform a verification of a boot image. In the case boot image 105, or one or more portions thereof, is determined by the verification to be unusable (for example, corrupted), instructions 109 may access secure location 107 to load the operating system using secure image 108. Alternatively, on determining boot image 105 cannot be verified or is unusable, instructions 109 may attempt to load and perform a second verification of a redundant boot image 106. In the case redundant boot image 106 is also determined by the second verification to be unusable, the software may load and execute secure boot image 108.

As system 100 is booted, a cryptographic key may be used to verify the boot image, or a portion of the boot image. In this regard, system 100 may perform a checksum at each level up from a core trusted piece of boot code, and, if a code abnormality and/or boot failure is determined, a redundant copy of the image, or one or more portions thereof, may be loaded to recover the boot path. Redundant image 106 (and secure image 108) may include a copy of the entire image or one or more levels of boot code, and may also be verified with the cryptographic key. As previously described, if the redundant copy is determined to be unusable, system 100 may recover the level of boot code from secure memory location 107.

Boot image 105, redundant boot image 106, and secure boot image 108 may include a boot code for a single boot level, or may include code partitioned into multiple levels. Since boot code may be restored on a level by level basis, once an unusable image, or portion thereof, is determined, the process may be operable to stop the boot cycle, access redundant copy 106 and/or secure copy 108 to repair that portion of code, and then resume the boot cycle at the last known verifiable level. For example, if there is a failure at the firmware level (EC to read-only to rewritable) the process may restart at the next firmware level. However, if the kernel fails then it may restart the boot verification process at the end of the firmware levels. During the recovery process, if redundant boot code stored, for example, on a recovery partition of a hard drive is also found to be unusable, the system (automatically, or on a user-initiated keystroke or switch) may copy the relevant portion of secure image 108 from secure location 107 to hard drive 104 or the like, replacing the unusable redundant boot code. The redundant boot code may be further checked using the cryptographic key to verify that the secure image was copied correctly and/or that there are no hardware errors.

As described previously, secure location 107 may include a non-removable chip, for example, eMMC, EEPROM, NAND flash, or the like. Alternatively, the secure recovery image may be stored in a host protected area of a solid state drive, hidden from the operating system. For example, secure recovery image 108 may be stored on a write-protected partition of an eMMC of the drive, in another aspect, secure recovery image 108 may be stored on a secure digital (SD) or micro SD card. A computer implementation of system 100 may include a hidden slot inside the device, for example, inside the battery compartment. A recovery image may be updated by removing it from the computer and programming it on a separate computer (or by inserting it into the normal SD card slot on the device itself). In one example, an SD or micro SD recovery image may be kept separate from the main memory medium of the device, with system 100 configured ignore the advertisement of the memory medium's write protect switch to the operating system.

According to one aspect, an additional circuit may be provided with the SD device to prevent intrusion. This circuit may be latched in either an enabled state or disabled state. Once a state has been selected, it may stay active (for example, cannot be changed) until the system resets. When the circuit is enabled, the SD card may be electrically connected so that system 100 can boot from it. When the circuit is disabled, the SD card may be electrically disconnected, and the system may not boot to or write from it, protecting it from being altered by a malfunctioning operating system or remote attacker. In one aspect, the circuit state may be selected via a read-only boot stub firmware (for example, in firmware 103). If system 100 determines that a recovery mode has been selected, it may enable the circuit. Otherwise, if it determines that the firmware should be rewritable, it may disable the circuit. In one example, the circuit state may be selected if a recovery button is activated on hardware associated with system 100.

The previously described additional circuitry may also be included in an integrated circuit and/or full chip protection implementation so that the chip is operable only in recovery mode. In this regard, the additional circuit may control the write protect state of the chip so that the chip is writable in recovery mode, but read-only in other modes. To this end, the chip may be protected from accidental or malicious alteration during normal hoot, but may still allow updating the recovery image when in recovery mode.

FIG. 2 is an exemplary diagram of an apparatus and system for restoring an operating system over a network according to one aspect of the subject technology. In some aspects, the previously described recovery mechanism may only install enough information to get to the operating system to a known good state, wherein the remainder of a core image may be pulled from other sources. For example, a computer-enabled device 200 may include one or more boot images on a firmware 201, memory medium 202 (for example, a hard drive), and/or secure memory 203 to restore the operating system to a default version (for example, as discussed with reference to FIG. 1). In one aspect, the one or more boot images may include a network recovery image of a default operating system, including a limited feature set with network accessibility. After installation, the default operating system may automatically, or on user action, initiate a predefined sequence to pull updates from over a network 204 in order to update the operating system to the latest version. Updates to the operating system may be provided by one or more remote servers 205. In this manner, the recovery process may first restore the computer to a usable place within a short period of time (for example, 30 seconds for a fast boot path) using the onboard recovery process, and then update the operating system in one or more background processes, providing the up-to-date operating system for use the next time the user reboots the computer.

In some aspects, as further operating system and firmware updates are released, secure image 108 may be automatically updated. In this manner, when the system needs to recover, the operating system and/or firmware can recover to an updated state instead of that which was available when the device already shipped from the factory. This may be significant in that the original factory software may have had security vulnerabilities at the time of its release. In a further aspect, system 100 may be configured to prevent the installation of an operating system that is older than the secure image. In this regard, on an attempt to install an operating system, a check may be performed against boot image 105, redundant image 106, or secure image 107 to verify that the operating system is at least as old as the image. The recovery image may also be able to disable the operating system protection so it can install the operating system and firmware which it contains, or it may include the previously described network recovery image so that it can fetch a current operating system and firmware over a network.

FIG. 3 is a flowchart illustrating an exemplary process for loading a boot image from a secure location according to one aspect of the subject technology. In step 301, system 100 initiates a sequence of boot cycles, with each cycle loading a level of boot code from a memory medium. In step 302, system 100 attempts to load and execute boot code for a boot cycle, and, in step 303, determines whether the boot code is usable. In one aspect, a verification of the code may be performed to determine whether it is usable to boot the device. In another aspect, the determination may result from a verification that the boot cycle did not fully execute, failed or produced errors, was corrupted, or the like.

If the boot code is usable, it is executed. Otherwise, in optional step 304, on determining the boot image is determined by the verification to be unusable, system 100 attempts to load a redundant copy of the boot code. As described previously, this copy may be loaded from a hidden partition on hard drive 104 or other memory medium. In some aspects, one or more cycles of boot code, including a redundant copy, may be loaded from a firmware, for example, a read/write firmware. If system 100 attempts to load a redundant copy of boot code, in step 305, system 100 will make a determination as to whether the redundant copy is also unusable. If the redundant boot code is usable, it is executed and the process ends. Otherwise, in step 306, on determining the both original and redundant boot images are determined to be unusable, system 100 attempts to load a secure copy of the boot code from a secure location. In some aspects, the secure location used to load the secure image is not associated with the memory medium. To this end, if a redundant copy is stored on one memory medium such as a hard drive or memory stick, the secure location may be implemented as a read only firmware, for example, in an integrated circuit

FIG. 4 is a diagram illustrating an exemplary server system for loading a boot image from a secure location, including a processor and other internal components, according to one aspect of the subject technology. In some aspects, a computerized device 400 (for example, computer system 100 or the like) includes several internal components such as a processor 401, a system bus 402, read-only memory 403, system memory 404, network interface 405, I/O interface 406, and the like. In one aspect, processor 401 may also be communication with a storage medium 407 (for example, a hard drive, database, or data cloud) via I/O interface 406. In some aspects, all of these elements of device 400 may be integrated into a single device. In other aspects, these elements may be configured as separate components.

Processor 401 may be configured to execute code or instructions to perform the operations and functionality described herein, manage request flow and address mappings, and to perform calculations and generate commands. Processor 401 is configured to monitor and control the operation of the components in server 400. The processor may be a general-purpose microprocessor, a microcontroller, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), a programmable logic device (PLD), a controller, a state machine, gated logic, discrete hardware components, or a combination of the foregoing. One or more sequences of instructions may be stored as firmware on a ROM within processor 401. Likewise, one or more sequences of instructions may be software stored and read from system memory 405, RUM 403, or received from a storage medium 407 (for example, via I/O interface 406). ROM 403, system memory 405, and storage medium 407 represent examples of machine or computer readable media on which instructions/code may be executable by processor 401. Machine or computer readable media may generally refer to any medium or media used to provide instructions to processor 401, including both volatile media, such as dynamic memory used for system memory 404 or for buffers within processor 401, and non-volatile media, such as electronic media, optical media, and magnetic media.

In some aspects, processor 401 is configured to communicate with one or more external devices (for example, via I/O interface 406). Processor 401 is further configured to read data stored in system memory 404 and/or storage medium 407 and to transfer the read data to the one or more external devices in response to a request from the one or more external devices. The read data may include one or more web pages and/or other software presentation to be rendered on the one or more external devices. The one or more external devices may include a computing system such as a personal computer, a server, a workstation, a laptop computer, PDA, smart phone, and the like.

In some aspects, system memory 404 represents volatile memory used to temporarily store data and information used to manage device 400. According to one aspect of the subject technology, system memory 404 is random access memory (RAM) such as double data rate (DDR) RAM, Other types of RAM also may be used to implement system memory 504. Memory 404 may be implemented using a single RAM module or multiple RAM modules. While system memory 404 is depicted as being part of device 400, those skilled in the art will recognize that system memory 404 may be separate from device 400 without departing from the scope of the subject technology. Alternatively, system memory 404 may be a non-volatile memory such as a magnetic disk, flash memory, peripheral SSD, and the like.

I/O interface 406 may be configured to be coupled to one or more external devices, to receive data from the one or more external devices and to send data to the one or more external devices. I/O interface 406 may include both electrical and physical connections for operably coupling I/O interface 406 to processor 401, for example, via, the bus 402. I/O interface 406 is configured to communicate data, addresses, and control signals between the internal components attached to bus 402 (for example, processor 401) and one or more external devices (for example, a hard drive). I/O interface 406 may be configured to implement a standard interface, such as Serial-Attached SCSI (SAS), Fiber Channel interface, PCI Express (PCIe), SATA, USB, and the like. I/O interface 406 may be configured to implement only one interface. Alternatively, I/O interface 406 may be configured to implement multiple interfaces, which are individually selectable using a configuration parameter selected by a user or programmed at the time of assembly. I/O interface 406 may include one or more buffers for buffering transmissions between one or more external devices and bus 402 and/or the internal devices operably attached thereto.

Those of skill in the art would appreciate that the various illustrative blocks, modules, elements, components, methods, and algorithms described herein may be implemented as electronic hardware, computer software, or combinations of both. To illustrate this interchangeability of hardware and software, various illustrative blocks, modules, elements, components, methods, and algorithms have been described above generally in terms of their functionality. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the overall system. Skilled artisans may implement the described functionality in varying ways for each particular application. Various components and blocks may be arranged differently (e.g., arranged in a different order, or partitioned in a different way) all without departing from the scope of the subject technology.

It is understood that the specific order or hierarchy of steps in the processes disclosed is an illustration of exemplary approaches. Based upon design preferences, it is understood that the specific order or hierarchy of steps in the processes may be rearranged. Some of the steps may be performed simultaneously. The accompanying method claims present elements of the various steps in a sample order, and are not meant to be limited to the specific order or hierarchy presented.

The previous description is provided to enable any person skilled in the art to practice the various aspects described herein. The previous description provides various examples of the subject technology, and the subject technology is not limited to these examples. Various modifications to these aspects will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other aspects. Thus, the claims are not intended to be limited to the aspects shown herein, but is to be accorded the full scope consistent with the language claims, wherein reference to an element in the singular is not intended to mean “one and only one” unless specifically so stated, but rather “one or more.” Unless specifically stated otherwise, the term “some” refers to one or more. Pronouns in the masculine (e.g., his) include the feminine and neuter gender (e.g., her and its) and vice versa. Headings and subheadings, if any, are used for convenience only and do not limit the invention.

The predicate words “configured to”, “operable to”, and “programmed to” do not imply any particular tangible or intangible modification of a subject, but, rather, are intended to be used interchangeably. For example, a processor configured to monitor and control an operation or a component may also mean the processor being programmed to monitor and control the operation or the processor being operable to monitor and control the operation. Likewise, a processor configured to execute code can be construed as a processor programmed to execute code or operable to execute code.

A phrase such as an “aspect” does not imply that such aspect is essential to the subject technology or that such aspect applies to all configurations of the subject technology, A disclosure relating to an aspect may apply to all configurations, or one or more configurations. An aspect may provide one or more examples. A phrase such as an aspect may refer to one or more aspects and vice versa. A phrase such as an “embodiment” does not imply that such embodiment is essential to the subject technology or that such embodiment applies to all configurations of the subject technology. A disclosure relating to an embodiment may apply to all embodiments, or one or more embodiments. An embodiment may provide one or more examples. A phrase such as an “embodiment” may refer to one or more embodiments and vice versa. A phrase such as a “configuration” does not imply that such configuration is essential to the subject technology or that such configuration applies to all configurations of the subject technology. A disclosure relating to a configuration may apply to all configurations, or one or more configurations. A configuration may provide one or more examples. A phrase such as a “configuration” may refer to one or more configurations and vice versa.

The word “exemplary” is used herein to mean “serving as an example or illustration.” Any aspect or design described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other aspects or designs.

All structural and functional equivalents to the elements of the various aspects described throughout this disclosure that are known or later come to be known to those of ordinary skill in the art are expressly incorporated herein by reference and are intended to be encompassed by the claims. Moreover, nothing disclosed herein is intended to be dedicated to the public regardless of whether such disclosure is explicitly recited in the claims. No claim element is to be construed under the provisions of 35 U.S.C. 012, sixth paragraph, unless the element is expressly recited using the phrase “means for” or, in the case of a method claim, the element is recited using the phrase “step for.” Furthermore, to the extent that the term “include,” “have,” or the like is used in the description or the claims, such term is intended to be inclusive in a manner similar to the term “comprise” as “comprise” is interpreted when employed as a transitional word in a claim. 

1. A computing device, comprising: a processor; one or more boot memories including a boot image and one or more boot images which correspond and are redundant to the boot image; a secure read-only location including at least one secure boot image; and a memory including initiation and recovery software for initiating a boot up of the computing device that, when executed by the processor, causes the processor to: load and perform a verification of a boot image; in the case the boot image is determined by the verification to be unusable, load and perform a second verification of a redundant boot image; and in the case the redundant boot image is determined by the second verification to be unusable, load a secure boot image from the secure read-only location.
 2. The computing device of claim 1, wherein performing a verification of a boot image includes the recovery software, when executed, causing the processor to: perform a verification of boot code at a plurality of boot code levels, wherein each level is verified up from a core trusted piece of boot code.
 3. The computing device of claim 2, wherein the boot image, redundant boot image, and secure boot image each include a copy of boot code for a single boot level.
 4. The computing device of claim 2, wherein the plurality of boot code levels include a boot cycle, and wherein determining the boot image to be unusable includes the recovery software, when executed, causing the processor to: stop the boot cycle; access the secure read-only location to load and repair a respective boot code, and resume the boot cycle at a last known verifiable level.
 5. The computing device of claim 1, wherein performing a verification of the boot image and the redundant boot image includes checking boot code using a cryptographic key.
 6. The computing device of claim 1, wherein the recovery software, when executed, further causes the processor to: perform a verification of the loaded secure boot image.
 7. The computing device of claim 6, wherein performing a verification of the loaded secure boot image includes checking boot code using a cryptographic key.
 8. The computing device of claim 1, wherein the secure read-only location includes an integrated circuit chip located on a system control board associated with the computing device.
 9. The computing device of claim 1, wherein the memory includes a separated hidden partition on a memory medium associated with the computing device.
 10. The computing device of claim 1, wherein the secure boot image is loaded in response to a user-initiated keystroke.
 11. The computing device of claim 1, wherein the secure boot image includes enough information to install an operating system of the computing device, and wherein the recovery software, when executed, further causes the processor to: restore the operating system to a default state including network accessibility; and initiate a predefined sequence to pull updates from a network source in order to update the operating system to a latest version.
 12. A machine-readable medium having machine-executable instructions stored thereon, which when executed by a machine or computer cause the machine or computer to perform a method of loading a boot image, comprising: initiating a sequence of boot cycles, each cycle loading a level of boot code from a memory medium; determining a level of boot code is unusable; and loading a secure copy of the level of boot code from a secure read-only location, wherein the secure read-only location is not associated with the memory medium.
 13. The machine-readable medium of claim 12, the method further comprising: verifying a last known verifiable level of code before determining the level of boot code is unusable; stopping the sequence of boot cycles on determining the level of boot code is unusable; repairing the unusable level of boot code using the secure copy; and resuming the boot cycle at the last known verifiable level.
 14. The machine-readable medium of claim 12, the method further comprising: before loading the secure copy, determining a redundant copy of the level of boot code is unusable.
 15. The machine-readable medium of claim 12, the method further comprising: performing a verification of the loaded secure boot image.
 16. The machine-readable medium of claim 12, wherein the secure read-only location includes an integrated circuit chip located on a system control board associated with the computing device.
 17. The machine-readable medium of claim 12, wherein the sequence of boot cycles up to the secure copy includes boot code to install an operating system of the computing device, the method further comprising: restoring the operating system to a default state including network accessibility; and initiating a predefined sequence to pull updates from a network source in order to update the operating system to a latest version.
 18. A computer-implemented method of recovering a boot image, comprising: determining a section of unusable boot code in a boot program, the boot program being stored on a memory medium; accessing a secure copy of boot code from a secure read-only integrated circuit; replacing the section of unusable boot code with the secure copy of boot code to repair the boot program on the memory medium; and loading a default operating system from the memory medium using the repaired boot program.
 19. The computer-implemented method of claim 18, wherein the default operating system includes just enough functionality to initiate a predefined sequence of operations to pull updates from a network source in order to update the operating system to a latest version
 20. The computer-implemented method of claim 18, further comprising: determining a redundant section of boot code corresponding to the section of unusable boot code is also unusable before replacing the section of unusable boot code with the secure copy of boot code; and replacing the redundant section of boot code with the secure copy of boot code.
 21. A computer-implemented method of recovering a boot image, comprising: determining an unusable boot image, the boot image being stored on a memory medium; accessing a secure copy of the boot image from a secure read-only integrated circuit; and loading an operating system using the secure copy.
 22. The computer-implemented method of claim 21, further comprising: replacing the unusable boot image with the secure copy to repair the boot image stored on the memory medium, wherein loading the default operating system using the secure copy includes loading the operating system from the memory medium using the repaired boot image.
 23. The computer-implemented method of claim 21, wherein the operating system is a default operating system including just enough functionality to initiate a predefined sequence of operations to pull updates from a network source in order to update the operating system to a latest version.
 24. The computer-implemented method of claim 21, further comprising: determining a redundant boot image corresponding to the unusable boot image is also unusable before replacing the unusable boot image with the secure boot image; and replacing the redundant boot image with the secure boot image. 